package basic;

import java.util.ArrayList;
import java.util.List;

/**
 * @Author: 海琳琦
 * @Date: 2021/8/27 20:19
 */
public class Title7 {
    public static void main(String[] args) {
        System.out.println((int)Math.pow(2,31 )-1);
        System.out.println(reverse(-2147483648));
    }

    private static int reverse(int x) {
        long n = 0;
        while(x!=0){
            n= n*10 + x%10;
            x = x/10;
        }
        if(n>Integer.MAX_VALUE-1||n<Integer.MIN_VALUE){
            return 0;
        }
        return (int)n;
    }
}
